package com.lj.domain;

/**
 * Created by dave on 2017/12/8.
 */
public class MsgInfo implements IDomain {
    private int id;
    private long createTime;
    private long receiveTime;
    private int status;//0初识状态，1已接收
    private int type;//0普通，1总是被接收
    private String sender;//发送人
    private String receiver;//接收人
    private String content;//内容

    @Override
    public String toJson() {
        return "{" +
                "'id':" + id +
                ",'createTime':" + createTime +
                ",'receiveTime':" + receiveTime +
                ",'status':" + status +
                ",'type':" + type +
                ",'sender':'" + sender + "'" +
                ",'receiver':'" + receiver + "'" +
                ",'content':'" + content + "'" +
                "}";
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(long createTime) {
        this.createTime = createTime;
    }

    public long getReceiveTime() {
        return receiveTime;
    }

    public void setReceiveTime(long receiveTime) {
        this.receiveTime = receiveTime;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }

    public String getSender() {
        return sender;
    }

    public void setSender(String sender) {
        this.sender = sender;
    }

    public String getReceiver() {
        return receiver;
    }

    public void setReceiver(String receiver) {
        this.receiver = receiver;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public MsgInfo() {
    }

    public MsgInfo(int id, long createTime, long receiveTime, int status, int type, String sender, String receiver, String content) {
        this.id = id;
        this.createTime = createTime;
        this.receiveTime = receiveTime;
        this.status = status;
        this.type = type;
        this.sender = sender;
        this.receiver = receiver;
        this.content = content;
    }

    @Override
    public String toString() {
        return "MsgInfo{" +
                "id=" + id +
                ", createTime=" + createTime +
                ", receiveTime=" + receiveTime +
                ", status=" + status +
                ", type=" + type +
                ", sender='" + sender + '\'' +
                ", receiver='" + receiver + '\'' +
                ", content='" + content + '\'' +
                '}';
    }
}
